<script setup lang="ts">
import {ref} from "vue";

const visible = ref(false)
const dataInfo = ref(false)
const URL = ref(import.meta.env.VITE_API_URL)
const init = (data) => {
  console.log(data.name)
  dataInfo.value = data
  visible.value = true
}
defineExpose({
  init
})
</script>

<template>
  <el-dialog v-model="visible" title="开发接入信息" :close-on-click-modal="false">
    <el-descriptions
        class="margin-top"
        :column="1"
    >
      <el-descriptions-item label="公众号">{{ dataInfo?.name }}</el-descriptions-item>
      <el-descriptions-item label="token">{{ dataInfo?.token }}</el-descriptions-item>
      <el-descriptions-item label="aesKey">{{ dataInfo?.aesKey }}</el-descriptions-item>
      <el-descriptions-item label="接入链接"> {{ URL }} +{{ dataInfo?.appid }}</el-descriptions-item
      >
    </el-descriptions>
  </el-dialog>
</template>

<style scoped lang="scss">
.cell-item {
  display: flex;
  align-items: center;
}
</style>
